/**
 * 
 */
package com.base.myproject.client.tools.fileupload;

/**
 * @author zgw
 *2009-8-7 上午08:08:37
 * javazgw@gmail.com
 */

import com.google.gwt.user.client.ui.HTML;
import com.google.gwt.user.client.ui.PopupPanel;
import com.google.gwt.user.client.ui.Widget;

/**
 *<p>
 * Modal progress widget that implements the IUploadStatus interface.
 *</p>
 *
 * @author Manolo Carrasco Moñino
 * 
 * 
 */
public class BasicModalProgress extends BasicProgress {
	PopupPanel box = new PopupPanel(false, true);
	
	public BasicModalProgress() {
		super();
		box.add(super.getWidget());
		box.addStyleName("GWTupld");
		box.addStyleName("upld-status");
//		setProgressWidget(new ProgressBar());
  }
	
	/**
	 * Returns an empty html widget
	 */
	@Override public Widget getWidget() {
		return new HTML();
		
	};
	
	/**
	 * show/hide the modal dialog
	 */
	@Override
	public void setVisible(boolean b) {
		if (b)
		  box.center();
		else
			box.hide();
	}
}
